<template>
  <div class="analysisBox">
    <div class="headCard">
      <div class="headCard_left headCard_public">
        <i class="el-icon-shopping-cart-full"/>
        <div class="headCard_title">
          已购资产：
          <span>{{ buyAssetNum }}</span>
        </div>
      </div>
      <div class="headCard_right headCard_public">
        <i class="el-icon-coin"/>
        <div class="headCard_title">
          资产总数：
          <span>{{ assetTotalNum }}</span>
        </div>
      </div>
    </div>
    <line-chart :options="options" width="100%" height="450px" class-name="line-chart"/>
  </div>
</template>
<script>
import LineChart from '@/components/Charts/lineMarker'
export default {
  components: {
    LineChart
  },
  data() {
    return {
      buyAssetNum: '30',
      assetTotalNum: '88',
      options: {
        backgroundColor: '#fff',
        tooltip: {
          trigger: 'axis',
          axisPointer: {
            lineStyle: {
              color: '#57617B'
            }
          }
        },
        legend: {
          top: 20,
          icon: 'rect',
          itemWidth: 14,
          itemHeight: 5,
          itemGap: 13,
          data: [''],
          right: '1%',
          textStyle: {
            fontSize: 14,
            color: '#F1F1F3'
          }
        },
        grid: {
          top: 50,
          left: 0,
          right: '1%',
          bottom: '2%',
          containLabel: true
        },
        xAxis: [{
          type: 'category',
          boundaryGap: true,
          axisLine: {
            lineStyle: {
              color: '#8a8a8a'
            }
          },
          data: ['13:00', '13:05', '13:10', '13:15', '13:20', '13:25', '13:30', '13:35', '13:40', '13:45', '13:50', '13:55']
        }],
        yAxis: [{
          type: 'value',
          name: '曝光次数',
          axisTick: {
            show: false
          },
          axisLine: {
            show: false,
            lineStyle: {
              // color: '#57617B'
            }
          },
          axisLabel: {
            margin: 10,
            textStyle: {
              fontSize: 14
            }
          },
          splitLine: {
            lineStyle: {
              show: false,
              color: '#8a8a8a'
            }
          }
        }],
        series: [
          {
            name: '统计',
            type: 'line',
            smooth: true,
            symbol: 'circle',
            symbolSize: 5,
            showSymbol: false,
            lineStyle: {
              normal: {
                width: 2
              }
            },
            areaStyle: {
              show: false
            },
            itemStyle: {
              normal: {
                color: 'rgb(0,136,212)',
                borderColor: 'rgba(0,136,212,0.2)',
                borderWidth: 12
              }
            },
            data: [120, 110, 125, 145, 122, 165, 122, 220, 182, 191, 134, 150]
          }
        ]
      }
    }
  }
}
</script>
<style lang="scss" scoped>
.analysisBox {
  padding: 20px;
  padding-top: 0;
  .headCard {
    color: #fff;
    .headCard_public {
      width: 42%;
      margin: 20px 50px;
      display: inline-block;
      padding: 20px;
      border-radius: 5px;
      box-shadow: 0px 2px 10px #909399;
      vertical-align: middle;
      text-align: center;
      i {
        zoom: 4;
      }
    }
    .headCard_title {
      display: inline-block;
      font-size: 35px;
      margin-left: 30px;
      span {
        font-size: 40px;
      }
    }
    .headCard_left {
      background-color: rgb(0, 216, 115);
    }
    .headCard_right {
      background-color: rgb(42, 149, 236);
    }
  }
}
</style>

